home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-03 / 123w20.zip / LSETCOLS.BAS < prev    next >
BASIC Source File  |  1990-11-15  |  719b  |  27 lines

  1. DEFINT A-Z
  2.  
  3. DECLARE SUB lSetCols (intArray%())
  4.  
  5. DEFINT A-Z
  6. SUB lSetCols (colArray(1)) STATIC
  7.  
  8.     'By using the lbound and ubound functions a series of columns
  9.     'can have their width set by calling this routine.  Dim the
  10.     'array from the first column and up to the last column to be
  11.     'be set.  The array element # specifies the column, the integer
  12.     'in the array element specifies the column width (up to 240).
  13.    
  14.     start = LBOUND(colArray)
  15.     finish = UBOUND(colArray)
  16.  
  17.     IF start < 0 OR finish > 255 THEN EXIT SUB
  18.  
  19.     FOR i = start TO finish
  20.         IF colArray(i) > 0 AND colArray(i) < 241 THEN
  21.             CALL lSetCol(i, colArray(i))
  22.         END IF
  23.     NEXT
  24.  
  25. END SUB
  26.  
  27.